package lpg;

public class Lpgprs implements Lpgsym {
    public final static int ERROR_SYMBOL = 38;
    public final int getErrorSymbol() { return ERROR_SYMBOL; }

    public final static int SCOPE_UBOUND = -1;
    public final int getScopeUbound() { return SCOPE_UBOUND; }

    public final static int SCOPE_SIZE = 0;
    public final int getScopeSize() { return SCOPE_SIZE; }

    public final static int MAX_NAME_LENGTH = 24;
    public final int getMaxNameLength() { return MAX_NAME_LENGTH; }

    public final static int NUM_STATES = 87;
    public final int getNumStates() { return NUM_STATES; }

    public final static int NT_OFFSET = 38;
    public final int getNtOffset() { return NT_OFFSET; }

    public final static int LA_STATE_OFFSET = 487;
    public final int getLaStateOffset() { return LA_STATE_OFFSET; }

    public final static int MAX_LA = 3;
    public final int getMaxLa() { return MAX_LA; }

    public final static int NUM_RULES = 138;
    public final int getNumRules() { return NUM_RULES; }

    public final static int NUM_NONTERMINALS = 48;
    public final int getNumNonterminals() { return NUM_NONTERMINALS; }

    public final static int NUM_SYMBOLS = 86;
    public final int getNumSymbols() { return NUM_SYMBOLS; }

    public final static int SEGMENT_SIZE = 8192;
    public final int getSegmentSize() { return SEGMENT_SIZE; }

    public final static int START_STATE = 173;
    public final int getStartState() { return START_STATE; }

    public final static int IDENTIFIER_SYMBOL = 0;
    public final int getIdentifier_SYMBOL() { return IDENTIFIER_SYMBOL; }

    public final static int EOFT_SYMBOL = 30;
    public final int getEoftSymbol() { return EOFT_SYMBOL; }

    public final static int EOLT_SYMBOL = 30;
    public final int getEoltSymbol() { return EOLT_SYMBOL; }

    public final static int ACCEPT_ACTION = 348;
    public final int getAcceptAction() { return ACCEPT_ACTION; }

    public final static int ERROR_ACTION = 349;
    public final int getErrorAction() { return ERROR_ACTION; }

    public final static boolean BACKTRACK = false;
    public final boolean getBacktrack() { return BACKTRACK; }

    public final int getStartSymbol() { return lhs(0); }
    public final boolean isValidForParser() { return Lpgsym.isValidForParser; }


    public interface IsNullable {
        public final static byte isNullable[] = {0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,1,0,
            0,0,1,0,0,1,1,1,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,1,0,0,0,0,0,0,
            0,1,0,0,0,0
        };
    };
    public final static byte isNullable[] = IsNullable.isNullable;
    public final boolean isNullable(int index) { return isNullable[index] != 0; }

    public interface ProsthesesIndex {
        public final static byte prosthesesIndex[] = {0,
            5,28,32,31,39,42,33,41,2,3,
            4,6,7,8,9,10,11,12,13,14,
            15,16,17,18,19,20,21,22,23,24,
            25,26,27,29,30,34,35,36,37,38,
            40,43,44,45,46,47,48,1
        };
    };
    public final static byte prosthesesIndex[] = ProsthesesIndex.prosthesesIndex;
    public final int prosthesesIndex(int index) { return prosthesesIndex[index]; }

    public interface IsKeyword {
        public final static byte isKeyword[] = {0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0
        };
    };
    public final static byte isKeyword[] = IsKeyword.isKeyword;
    public final boolean isKeyword(int index) { return isKeyword[index] != 0; }

    public interface BaseCheck {
        public final static byte baseCheck[] = {0,
            1,0,3,3,3,3,3,3,3,3,
            3,3,3,3,3,3,3,3,3,3,
            3,3,3,3,3,1,2,1,2,1,
            3,1,1,1,1,2,4,1,2,1,
            3,1,1,1,1,2,1,2,3,4,
            3,0,2,1,2,4,1,2,1,2,
            2,3,4,0,1,1,2,1,2,1,
            2,1,2,1,1,1,4,4,4,4,
            4,4,1,1,1,1,1,1,1,1,
            1,2,1,2,1,2,1,2,1,2,
            1,1,2,2,3,4,5,3,1,1,
            1,1,0,2,3,2,2,1,1,2,
            1,2,3,3,1,3,1,4,1,1,
            1,1,1,1,0,1,0,2,-3,-32,
            0,-53,-11,0,0,-26,0,0,-2,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,-1,-12,0,-20,0,-10,0,0,
            0,0,0,-13,0,0,0,0,-14,0,
            -16,0,0,-15,0,-21,0,-23,0,0,
            -24,0,-25,0,-27,0,0,0,-46,0,
            -28,0,0,-29,0,0,0,-30,0,-38,
            -55,0,0,-70,-31,0,-34,0,0,-4,
            0,0,-5,0,-6,0,-7,0,-8,0,
            0,-17,0,-9,0,0,-18,-19,-22,-36,
            0,0,0,-33,0,-35,-37,-39,0,0,
            0,0,0,-40,-41,-49,0,0,0,-42,
            -43,-44,0,0,0,-45,-47,-68,0,0,
            -48,-50,0,-52,0,0,-54,-51,-56,-57,
            0,-58,-59,0,0,0,-60,0,0,-61,
            -62,-63,0,-66,-65,0,0,0,-64,0,
            -71,0,0,-72,-73,-67,0,0,-74,0,
            0,-76,-78,-79,0,0,-80,0,-82,-81,
            -69,0,0,0,-83,-84,0,0,-85,-86,
            -87,0,0,0,-75,-77,0
        };
    };
    public final static byte baseCheck[] = BaseCheck.baseCheck;
    public final int baseCheck(int index) { return baseCheck[index]; }
    public final static byte rhs[] = baseCheck;
    public final int rhs(int index) { return rhs[index]; };

    public interface BaseAction {
        public final static char baseAction[] = {
            9,9,10,10,10,10,10,10,10,10,
            10,10,10,10,10,10,10,10,10,10,
            10,10,10,10,10,10,11,11,12,12,
            13,13,34,34,35,14,14,14,15,15,
            16,16,37,37,37,38,38,39,39,40,
            40,40,36,36,17,17,17,20,20,21,
            21,41,41,41,8,8,22,22,23,23,
            19,19,18,18,4,4,25,25,25,25,
            25,25,25,42,6,6,6,6,6,6,
            6,24,24,27,27,28,28,29,29,30,
            30,43,43,31,31,45,45,45,45,3,
            3,3,3,5,5,5,5,5,2,32,
            32,46,46,47,47,33,33,26,26,7,
            7,7,7,7,7,1,1,44,44,477,
            222,24,35,108,4,29,108,19,94,451,
            244,143,174,184,189,239,191,237,235,233,
            176,196,230,198,201,203,146,205,211,214,
            218,140,254,34,610,5,146,13,32,53,
            331,278,149,139,616,6,120,266,256,616,
            7,616,9,39,574,257,616,14,627,16,
            67,507,17,517,18,108,20,96,227,148,
            276,108,21,98,108,22,100,60,184,23,
            687,688,65,65,676,73,65,618,61,62,
            552,15,63,552,12,552,11,552,10,552,
            8,92,546,258,552,3,73,672,674,680,
            109,71,58,69,683,25,528,538,557,284,
            287,289,31,209,557,557,509,290,292,281,
            557,557,557,293,297,300,557,545,698,301,
            305,629,557,138,536,316,142,536,637,526,
            526,37,526,526,56,82,81,526,80,79,
            526,536,120,78,694,120,77,311,128,549,
            319,478,315,117,557,120,696,323,345,564,
            324,117,553,120,647,329,117,120,335,120,
            557,700,336,339,340,652,657,117,117,120,
            662,667,117,117,341,186,609,349,349
        };
    };
    public final static char baseAction[] = BaseAction.baseAction;
    public final int baseAction(int index) { return baseAction[index]; }
    public final static char lhs[] = baseAction;
    public final int lhs(int index) { return lhs[index]; };

    public interface TermCheck {
        public final static byte termCheck[] = {0,
            0,1,2,3,4,5,6,7,8,9,
            10,11,12,13,14,15,16,17,18,19,
            20,21,22,23,24,25,26,27,28,29,
            30,0,1,0,0,35,36,37,0,1,
            2,3,4,5,6,7,8,9,10,11,
            12,13,14,15,16,17,18,19,20,21,
            22,23,24,25,26,27,28,29,30,35,
            36,37,0,35,36,37,0,1,2,3,
            4,5,6,7,8,9,10,11,12,13,
            14,15,16,17,18,19,20,21,22,23,
            24,25,26,27,28,29,30,0,0,2,
            3,35,36,37,0,1,2,3,4,0,
            6,7,8,9,10,11,12,13,14,15,
            16,17,18,19,20,21,22,23,24,25,
            26,27,28,29,30,0,1,0,3,35,
            36,37,0,1,2,3,4,10,6,7,
            8,9,10,11,12,13,14,15,16,17,
            18,19,20,21,22,23,24,25,26,27,
            28,29,30,0,1,0,3,35,36,37,
            0,1,2,3,4,10,6,7,8,9,
            10,11,12,13,14,15,16,17,18,19,
            20,21,22,23,24,25,26,27,28,29,
            30,0,1,0,3,35,36,37,0,1,
            2,3,4,5,6,7,8,9,10,11,
            12,13,14,15,16,17,18,19,20,21,
            22,23,24,25,26,27,28,29,30,0,
            1,2,3,4,5,6,7,8,9,10,
            11,12,13,14,15,16,17,18,19,20,
            21,22,23,24,25,26,27,28,29,30,
            0,1,2,3,4,5,6,7,8,9,
            10,11,12,13,14,15,16,17,18,19,
            20,21,22,23,24,25,26,27,28,29,
            30,0,1,2,3,4,5,6,7,8,
            9,10,11,12,13,14,15,16,17,18,
            19,20,21,22,23,24,25,26,27,28,
            29,30,0,1,2,3,4,0,6,7,
            8,9,10,11,12,13,14,15,16,17,
            18,19,20,21,22,23,24,25,26,27,
            28,29,30,0,1,2,3,4,0,6,
            7,8,9,10,11,12,13,14,15,16,
            17,18,19,20,21,22,23,24,25,26,
            27,28,29,30,0,1,2,3,4,0,
            6,7,8,9,10,11,12,13,14,15,
            16,17,18,19,20,21,22,23,24,25,
            26,27,28,29,30,0,1,2,3,4,
            0,6,7,8,9,10,11,12,13,14,
            15,16,17,18,19,20,21,22,23,24,
            25,26,27,28,29,30,0,0,1,2,
            30,4,6,7,8,9,0,11,12,13,
            14,15,16,17,18,19,20,21,22,23,
            24,25,26,27,28,29,0,1,0,3,
            2,5,6,7,8,9,0,1,10,3,
            4,5,6,7,8,0,1,0,0,4,
            5,6,7,8,9,0,1,0,0,4,
            5,6,7,8,0,0,1,0,0,5,
            5,0,0,5,3,0,0,5,31,32,
            33,34,0,0,1,2,0,4,31,32,
            33,34,0,0,1,31,32,33,34,31,
            32,33,34,31,32,33,34,31,32,33,
            34,0,0,31,32,33,34,31,32,33,
            34,0,0,31,32,33,34,0,0,0,
            1,0,3,5,5,0,1,0,3,2,
            5,0,31,32,33,34,0,1,0,3,
            2,5,31,32,33,34,0,1,31,32,
            33,34,31,32,33,34,0,1,2,0,
            4,0,1,2,0,4,0,1,2,0,
            4,0,1,2,0,4,0,1,2,0,
            4,0,1,0,1,0,5,2,5,0,
            1,0,0,1,5,3,0,0,2,2,
            0,5,5,0,1,0,1,0,1,0,
            1,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0,0,0,
            0,0,0,0,0,0,0,0
        };
    };
    public final static byte termCheck[] = TermCheck.termCheck;
    public final int termCheck(int index) { return termCheck[index]; }

    public interface TermAction {
        public final static char termAction[] = {0,
            51,346,346,346,346,602,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,26,376,2,41,346,346,346,49,346,
            346,346,346,640,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,394,
            393,396,137,346,346,346,50,346,346,346,
            346,678,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,135,52,467,
            485,346,346,346,51,346,346,346,346,113,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,135,220,104,485,346,
            346,346,49,346,346,346,346,302,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,135,277,48,485,346,346,346,
            50,346,346,346,346,327,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,135,282,349,485,346,346,346,108,346,
            346,346,346,840,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,105,
            346,346,346,346,871,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            106,346,346,346,346,902,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,107,346,346,346,346,933,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,108,346,346,346,346,349,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,105,346,346,346,346,349,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,106,346,346,346,346,349,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,107,346,346,346,346,
            349,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,346,346,346,346,
            346,346,346,346,346,346,1,108,716,467,
            348,465,247,248,249,242,349,377,444,446,
            379,384,403,425,440,468,225,476,442,448,
            387,194,178,408,415,474,135,264,121,485,
            471,432,1060,1079,1050,1054,135,478,304,485,
            480,479,1095,1099,1089,349,433,36,349,438,
            434,436,435,439,437,349,478,55,349,480,
            479,482,481,483,349,72,423,349,349,309,
            424,135,349,314,485,349,349,330,458,459,
            460,461,135,105,747,467,135,465,458,459,
            460,461,135,40,250,458,459,460,461,458,
            459,460,461,458,459,460,461,458,459,460,
            461,135,349,265,265,265,265,270,270,270,
            270,135,349,271,271,271,271,135,114,135,
            382,135,485,464,381,135,423,349,485,383,
            424,349,272,272,272,272,135,450,103,485,
            467,451,483,483,483,483,349,475,482,482,
            482,482,481,481,481,481,106,778,467,349,
            465,107,809,467,349,465,51,488,467,349,
            465,49,526,467,349,465,50,564,467,349,
            465,70,423,57,423,64,424,467,424,68,
            423,349,135,288,424,485,64,64,467,467,
            349,221,224,349,473,349,472,43,322,42,
            395
        };
    };
    public final static char termAction[] = TermAction.termAction;
    public final int termAction(int index) { return termAction[index]; }

    public interface Asb {
        public final static char asb[] = {0,
            136,159,136,135,135,135,135,135,135,64,
            32,63,63,63,64,63,63,63,63,64,
            63,63,63,63,1,32,32,32,32,64,
            31,64,64,57,59,132,59,30,92,92,
            92,92,92,92,92,99,91,31,98,92,
            89,23,132,23,30,22,22,22,22,22,
            22,23,97,91,97,89,89,131,131,31,
            97,92,97,97,130,91,127,97,97,128,
            92,128,97,128,128,128,128
        };
    };
    public final static char asb[] = Asb.asb;
    public final int asb(int index) { return asb[index]; }

    public interface Asr {
        public final static byte asr[] = {0,
            11,12,13,14,15,16,17,18,19,20,
            21,22,23,24,25,26,27,28,29,30,
            3,9,1,5,4,7,6,8,0,5,
            1,11,12,13,14,15,16,6,9,7,
            8,17,18,19,20,21,22,23,24,25,
            26,27,28,29,30,3,2,0,31,32,
            33,34,5,11,12,13,14,15,16,6,
            9,7,8,17,18,19,20,21,3,22,
            23,24,25,26,27,28,29,30,1,0,
            5,31,32,33,34,0,4,2,11,12,
            13,14,15,16,6,9,7,8,17,18,
            19,20,21,3,22,23,24,25,26,27,
            28,29,1,30,10,0,5,4,2,10,
            1,35,36,37,3,11,12,13,14,15,
            16,6,9,7,8,17,18,19,20,21,
            22,23,24,25,26,27,28,29,30,0
        };
    };
    public final static byte asr[] = Asr.asr;
    public final int asr(int index) { return asr[index]; }

    public interface Nasb {
        public final static byte nasb[] = {0,
            34,24,1,26,26,26,26,26,26,24,
            31,36,42,42,24,42,43,43,43,39,
            42,43,45,48,51,31,31,31,31,54,
            59,25,26,61,65,63,65,57,65,65,
            65,65,65,65,65,24,65,32,24,65,
            24,52,28,52,57,69,69,69,69,69,
            69,52,71,65,71,24,24,67,24,57,
            32,65,71,32,24,65,24,71,32,71,
            65,71,32,32,71,32,32
        };
    };
    public final static byte nasb[] = Nasb.nasb;
    public final int nasb(int index) { return nasb[index]; }

    public interface Nasr {
        public final static byte nasr[] = {0,
            33,32,31,30,29,28,27,26,25,24,
            22,21,17,15,14,13,12,11,16,18,
            19,20,23,0,47,1,0,38,39,0,
            1,2,0,10,0,1,34,0,1,41,
            0,1,4,0,1,43,0,1,42,0,
            1,7,0,45,1,0,8,0,44,0,
            35,0,36,0,3,0,40,0,6,0,
            5,0
        };
    };
    public final static byte nasr[] = Nasr.nasr;
    public final int nasr(int index) { return nasr[index]; }

    public interface TerminalIndex {
        public final static byte terminalIndex[] = {0,
            36,37,20,15,35,10,12,13,11,33,
            4,5,6,7,8,9,14,16,17,18,
            19,21,22,23,24,25,26,27,28,38,
            29,30,31,32,1,2,3,39
        };
    };
    public final static byte terminalIndex[] = TerminalIndex.terminalIndex;
    public final int terminalIndex(int index) { return terminalIndex[index]; }

    public interface NonterminalIndex {
        public final static byte nonterminalIndex[] = {0,
            0,63,67,66,0,74,68,0,0,0,
            40,41,42,43,44,45,46,47,48,49,
            50,51,52,53,54,55,56,57,58,59,
            60,61,62,64,65,0,69,70,71,72,
            73,75,76,0,77,78,79,0
        };
    };
    public final static byte nonterminalIndex[] = NonterminalIndex.nonterminalIndex;
    public final int nonterminalIndex(int index) { return nonterminalIndex[index]; }
    public final static int scopePrefix[] = null;
    public final int scopePrefix(int index) { return 0;}

    public final static int scopeSuffix[] = null;
    public final int scopeSuffix(int index) { return 0;}

    public final static int scopeLhs[] = null;
    public final int scopeLhs(int index) { return 0;}

    public final static int scopeLa[] = null;
    public final int scopeLa(int index) { return 0;}

    public final static int scopeStateSet[] = null;
    public final int scopeStateSet(int index) { return 0;}

    public final static int scopeRhs[] = null;
    public final int scopeRhs(int index) { return 0;}

    public final static int scopeState[] = null;
    public final int scopeState(int index) { return 0;}

    public final static int inSymb[] = null;
    public final int inSymb(int index) { return 0;}


    public interface Name {
        public final static String name[] = {
            "",
            "%DropSymbols",
            "%DropActions",
            "%DropRules",
            "%Notice",
            "%Ast",
            "%Globals",
            "%Define",
            "%Terminals",
            "%SoftKeywords",
            "%Eol",
            "%Eof",
            "%Error",
            "%Identifier",
            "%Alias",
            "%Empty",
            "%Start",
            "%Types",
            "%Rules",
            "%Names",
            "%End",
            "%Headers",
            "%Trailers",
            "%Export",
            "%Import",
            "%Include",
            "%Prostheses",
            "%Recover",
            "%DisjointPredecessorSets",
            "::=",
            "::=?",
            "->",
            "->?",
            "|",
            "$empty",
            "MACRO_NAME",
            "SYMBOL",
            "BLOCK",
            "EOF",
            "ERROR_SYMBOL",
            "include_segment",
            "notice_segment",
            "define_segment",
            "terminals_segment",
            "export_segment",
            "import_segment",
            "softkeywords_segment",
            "eof_segment",
            "eol_segment",
            "error_segment",
            "prostheses_segment",
            "recover_segment",
            "identifier_segment",
            "start_segment",
            "alias_segment",
            "names_segment",
            "headers_segment",
            "ast_segment",
            "globals_segment",
            "trailers_segment",
            "rules_segment",
            "types_segment",
            "dps_segment",
            "action_segment",
            "macro_name_symbol",
            "macro_segment",
            "terminal_symbol",
            "produces",
            "name",
            "drop_command",
            "drop_symbols",
            "drop_rules",
            "drop_rule",
            "prosthesis",
            "alias_rhs",
            "alias_lhs_macro_name",
            "start_symbol",
            "rules",
            "type_declarationlist",
            "type_declarations"
        };
    };
    public final static String name[] = Name.name;
    public final String name(int index) { return name[index]; }

    public final int originalState(int state) {
        return -baseCheck[state];
    }
    public final int asi(int state) {
        return asb[originalState(state)];
    }
    public final int nasi(int state) {
        return nasb[originalState(state)];
    }
    public final int inSymbol(int state) {
        return inSymb[originalState(state)];
    }

    /**
     * assert(! goto_default);
     */
    public final int ntAction(int state, int sym) {
        return baseAction[state + sym];
    }

    /**
     * assert(! shift_default);
     */
    public final int tAction(int state, int sym) {
        int i = baseAction[state],
            k = i + sym;
        return termAction[termCheck[k] == sym ? k : i];
    }
    public final int lookAhead(int la_state, int sym) {
        int k = la_state + sym;
        return termAction[termCheck[k] == sym ? k : la_state];
    }
}
